package com.sinochem.yunlian.ship.common.enums;

/**
 * @Auther: panyanan
 * @Dscription:
 * @Date: Create in 2017/11/23 10:08
 **/
public enum InsurantCompany {


    PINGAN(1,"平安保险"),
    TAIPING(6,"太平洋保险");

    private int code;

    private String name;

    InsurantCompany(int code , String name){
        this.code = code;
        this.name = name;
    }

    public int getCode() {
        return code;
    }

    public String getName() {
        return name;
    }

    public void setCode(int code) {
        this.code = code;
    }

    public void setName(String name) {
        this.name = name;
    }

    public static String valueOf(int code){
        String name = "";
        switch ( code ) {
            case 1:
                name = "平安保险";
                break;
            case 6:
                name = "太平洋保险";
                break;
            default:
                name = "";
                break;
        }
        return name;
    }
}
